Skip to main content

The SHM Equation

To begin the discussion of SHM, we need to understand the equation that describes it.

Table of Contents

Introduction

Suppose we have a mass attached to a spring with spring constant . The spring is fixed at one end and the mass can move freely in the -direction. The position of the mass is the only degree of freedom in this system, labeled .

The spring is initially at its natural length , where . When the mass is displaced from its equilibrium position, it experiences a restoring force that tries to bring it back to its equilibrium position:

This means that:

This is a second-order differential equation, known as the equation of motion of a simple harmonic oscillator.

We can alternatively take a Lagrangian approach to derive the same equation. We know that the spring force is conservative, so we can write its potential energy as . As such, the Lagrangian is given by:

Plugging this into the Euler-Lagrange equation, we get:

This is the same equation we derived earlier. It is common to introduce the variable , which gives us the equation:

The Solution

We can solve this equation multiple ways. I will show three methods here.

First, the fastest way is to take an ansatz of the form:

This is a reasonable guess, as we know that the solution must be periodic. Plugging this into the equation of motion, we get:

This means that , so we can write the solution as 1:

Additionally, since the same reasoning applies to the sine function, we can also write the solution as a linear combination of sine and cosine:

Secondly, we can enforce energy conservation and derive a solution from there;

We can take on one side and on the other side:

We can then separate the variables and integrate both sides, which I will not do here (see this for a detailed derivation).

If one is familiar with Hamiltonian mechanics, one might instead consider the phase space of the system , where . We can then write the equation of motion as a first-order differential equation in the phase space:

The eigenvalues of the matrix are , and the eigenvectors are and . Thus, if we can write the initial conditions as a linear combination of the eigenvectors, we can write the solution as:

which means . We can then use Euler's formula to write this as:

where and are determined by the initial conditions.

Initial Conditions

The solution we derived above is a general solution to the equation of motion. Given that it is a second-order differential equation, we need two initial conditions to fully specify the solution. The two initial conditions can be the initial position and velocity of the mass.

Plugging in the initial conditions, we eventually get a solution of the form:

Parameters of the SHO

Given that we now have a solution to the equation of motion, we can now discuss the parameters of the SHO.

The amplitude is the maximum displacement of the mass from its equilibrium position. The amplitude is given by .

The period is the time it takes for the mass to complete one full oscillation. The period is given by ( is the Greek letter tau).

The frequency is the number of oscillations per unit time. It is given by (the Greek letter nu). The frequency is the inverse of the period.

The angular frequency is the rate of change of the phase of the oscillation. It is best understood if we consider the solution as the rotation of a complex number. Then, the angular frequency is just the angle's rate of change. It is given by .

Linear and Homogeneous Equations

With the introduction of the SHO, we can now discuss the general form of linear and homogeneous equations. The reason that so many physical systems can be modeled as SHOs is that they exhibit common behavior, or at least approximately common behavior. The behavior that we are interested in include the linearity and time-translational invariance of the system.

In a system (with one degree of freedom ), the equation of motion is linear if each term contains at most one factor of . This means that the equation of motion can be written in the form:

By varying the coefficients , , and , we can model a wide variety of systems. Note that they do not need to be constant; they can be functions of time.

The function is a forcing function, which describes the external forces acting on the system. For instance, if a mass-spring system is vertically hung and is subject to gravity, then we can write the equation of motion as:

or

Suppose we have a solution to the above equation of motion. If we define , then we can write the equation of motion as:

This means that the solution to the equation of motion is the same as if there was no external force acting on the system. In other words, the presence of a gravitational force does not change the oscillation of the mass-spring system. It only "pushes down" the equilibrium position of the mass.

A homogeneous equation is one where the right-hand side () is zero; all terms have one factor of . As such, the homogeneous part of the equation is given by:

Suppose we have a solution that satisfies the linear equation with and a solution that satisfies the linear equation with . Then, the linear combination of the two solutions is also a solution to the linear equation with . This is known as the principle of superposition.

Notice that whenever we have a particular solution to the linear equation, we can always add a solution to the homogeneous equation to get another solution to the linear equation. This means that the general solution to the linear equation is given by the sum of the particular solution and the general solution to the homogeneous equation:

where is a particular solution to the linear equation and is the general solution to the homogeneous equation.

Approximations as SHOs

Many systems can be approximated as SHOs. To see this, we first write the equation of motion in terms of the potential energy :

We can then Taylor expand the potential energy around the equilibrium position (which we will take to be zero for simplicity):

For SHOs, the first derivative is also zero because the force is zero and . For the second derivative, we have .

In a real system, we have higher-order terms in the Taylor expansion. With sufficiently small displacements (), the higher-order terms get more and more negligible.

For the term, this term is negligible if the term overpowers it. In other words, . Equivalently:

Overall, this means that any with a local minimum at a point can be approximated as a SHO if the displacement from the equilibrium position is small enough. This is the case for many systems, including pendulums, springs, and even the motion of planets around the sun. It's also why we can use the harmonic approximation to describe the motion of atoms in a crystal lattice.

When a system fails to be approximated as a SHO, this happens because of two reasons. First, the potential energy might not be analytic around the equilibrium position. Then, we cannot Taylor expand the potential energy. Second, if is zero, then must also be zero (because it is proportional to . If it wasn't zero then the system will grow unbounded). However, this means that the term will dominate the potential energy.

Time Translation Invariance

The second property of the SHO is that it is time-translationally invariant. Take the homogeneous equation of motion:

and suppose all the coefficients are constant. Then only appears in the derivatives, and therefore the equation is invariant under time translations. In other words, if is a solution to the equation, then is also a solution for any .

The simplest way changes with time is by a multiplicative factor of ;

Solutions of this form are known as irreducible solutions because they behave the simplest under time translations. (More precisely, they are irreducible under the action of the time translation group. A full discussion of this involves representation theory.)

We shall now prove an important theorem:

If a system is linear and time-translationally invariant, then the solution to the equation of motion is a linear combination of irreducible complex exponentials.

We can prove this for a general equation of motion of a complex variable . Essentially, we write as a linear combination of functions, and then show that these functions have to be complex exponentials.

First, let's write as a linear combination of functions :

We can borrow language from linear algebra and call the the basis functions. They are to be complete, meaning that they can be used to express any function . They are also linearly independent, meaning that no can be expressed as a linear combination of the others.

Applying time translation to , we have:

Differentiating both sides with respect to gives us:

Then, setting gives us:

But this is just a simple differential equation whose solution is:

Indeed, the solution is an irreducible solution of the form .

To find out more about the system, we can apply more linear algebra. We apply time translation to , i.e. :

By definition, since is a solution, and the system is time-translationally invariant, is also a solution. We can write this time-translated solution as another linear combination of the basis functions:

where is a matrix that describes the transformation of the basis functions under time translation. This means that we can write:

Since this must be equal to , we can write:

Removing the sum over , we get:

Rearranging this gives us:

We can combine the two sums into one. To do so, we sum over in the second term, but introduce a Kronecker delta ;

Plugging this into the equation gives us:

Finally, if we introduce , we can write:

Once again, we borrow language from linear algebra. We can imagine a vector with coefficients and a matrix with values . The equation above can be written as:

The only way this can be satisfied is if the determinant of is zero. We can solve this as a polynomial equation in . It has a degree of , where is the number of basis functions. This means that there are roots , which are the eigenvalues of the matrix .

Energies

We conclude this section with a discussion of the energies of the SHO. In a most general case, an undamped and unforced SHO obeys the equation of motion:

where is the generalized mass and is the generalized spring constant. We use the word "generalized" because they might not literally be the mass and spring constant of the system. (For example, a pendulum-like system might use the moment of inertia as the generalized mass.)

The kinetic energy of the system is given by:

The potential energy of the system is given by:

For the generalized mass and spring constant to be valid, their dimensions must be set such that and have the dimensions of energy.

Footnotes

  1. The astute reader might notice that this only means that . However, cosine is an even function, so both solutions are equivalent. Additionally, for the sine term, using simply adds a factor of to the sine term, which can be absorbed into the amplitude.